<?php use_stylesheets_for_form($form) ?>
<?php use_javascripts_for_form($form) ?>
<form action="<?php echo url_for('webconfigs/index') ?>" method="post" >
            <table>
                <?php foreach($form as $widget): ?>
                    <?php if(!$widget->isHidden()): ?>
                        <tr>
                            <td><?php echo $widget->renderLabel() ?></td>
                            <td><?php echo $widget->render(array('style'=>'width:320px;')) ?></td>
                            <td><?php echo ($widget->hasError() ? $widget->getError() : $widget->renderHelp()) ?> </td>
                        </tr>
                     <?php endif ?>
                <?php endforeach; ?>
                <?php echo $form->renderHiddenFields() ?>
            </table>
            <table>
                <tr>
                    <td>
                        <input type="submit" value="保存信息" />
                    </td>
                    <td>
                        <input type="reset" value="默认设置" />
                    </td>
                </tr>
            </table>
</form>
<!--<form action="<?php //echo url_for('webconfigs/'.($form->getObject()->isNew() ? 'create' : 'update').(!$form->getObject()->isNew() ? '?id='.$form->getObject()->getId() : '')) ?>" method="post" <?php //$form->isMultipart() and print 'enctype="multipart/form-data" ' ?>>
<?php// if (!$form->getObject()->isNew()): ?>
<input type="hidden" name="sf_method" value="put" />
<?php// endif; ?>
  <table>
    <tfoot>
      <tr>
        <td colspan="2">
          &nbsp;<a href="<?php //echo url_for('webconfigs/index') ?>">Back to list</a>
          <?php// if (!$form->getObject()->isNew()): ?>
            &nbsp;<?php// echo link_to('Delete', 'webconfigs/delete?id='.$form->getObject()->getId(), array('method' => 'delete', 'confirm' => 'Are you sure?')) ?>
          <?php //endif; ?>
          <input type="submit" value="Save" />
        </td>
      </tr>
    </tfoot>
    <tbody>
      <?php //echo $form ?>
    </tbody>
  </table>
</form>
//-->